package JdbcPool;

import java.sql.Connection;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.sql.Statement;

/**
 * @author zxl
 * @version 1.0
 * @date 2021/10/14 20:53
 */
public class text {
    public static void main(String[] args) {
        for (int i = 0; i < 11; i++) {
            try {
                Connection connection = JdbcUtil.getConnection();
                System.out.println(i +" : "+ connection);
                System.out.println("查询成功，释放资源");
                JdbcUtil.release(connection,null,null);
                System.out.println();
                System.out.println();

            } catch (SQLException e) {
                e.printStackTrace();
            }
        }
    }
}
